import { firstType } from './filters'
const customerColumns = {
  paid: [
    {
      title: '所属顾问',
      dataIndex: 'username',
      scopedSlots: {
        filterDropdown: 'filterSelect'
      }
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '业务大类',
      dataIndex: 'first_type',
      scopedSlots: { customRender: 'first_type' },
      filters: firstType,
      filterMultiple: false,
      onFilter: (value, record) => record.first_type.indexOf(value) === 0
    },
    {
      title: '业务名称',
      dataIndex: 'tm_name',
      scopedSlots: {
        customRender: 'tm_name',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    // {
    //   title: '意向业务',
    //   dataIndex: 'customer_business'
    // },
    {
      title: '最近联系时间',
      dataIndex: 'lately_contact_time',
      sorter: true
    },
    {
      title: '最新进展',
      dataIndex: 'notes'
    },
    {
      title: '打款总额',
      dataIndex: 'amounts',
      sorter: true,
      scopedSlots: { customRender: 'amounts' }
    },
    {
      title: '领取时间',
      dataIndex: 'received_at',
      scopedSlots: {
        filterDropdown: 'filterRange'
      },
      sorter: true
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  unpay: [
    {
      title: '所属顾问',
      dataIndex: 'username',
      scopedSlots: {
        filterDropdown: 'filterSelect'
      }
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '业务名称',
      dataIndex: 'tm_name',
      scopedSlots: {
        customRender: 'tm_name',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '业务大类',
      dataIndex: 'first_type',
      scopedSlots: { customRender: 'first_type' },
      filters: firstType,
      filterMultiple: false,
      onFilter: (value, record) => record.first_type.indexOf(value) === 0
    },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    // {
    //   title: '意向业务',
    //   dataIndex: 'intentions'
    // },
    {
      title: '最近联系时间',
      dataIndex: 'lately_contact_time',
      sorter: true
    },
    {
      title: '最新进展',
      dataIndex: 'notes'
    },
    {
      title: '领取时间',
      dataIndex: 'received_at',
      scopedSlots: {
        filterDropdown: 'filterRange'
      },
      sorter: true
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  abandon: [
    {
      title: '客户姓名',
      dataIndex: 'customer_name'
    },
    {
      title: '商标名称',
      dataIndex: 'tm_name'
    },
    {
      title: '客户电话',
      dataIndex: 'phone'
    },
    {
      title: '意向业务',
      dataIndex: 'customer_business'
    },
    {
      title: '最近联系时间',
      dataIndex: 'lately_contact_time'
    },
    {
      title: '最新进展',
      dataIndex: 'newest_progress'
    },
    {
      title: '放弃时间',
      dataIndex: 'abandon_time'
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  question: [
    {
      title: '客户来源',
      dataIndex: 'source'
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name'
    },
    {
      title: '标记顾问',
      dataIndex: 'username',
      scopedSlots: {
        filterDropdown: 'filterSelect'
      }
    },
    {
      title: '标记内容',
      dataIndex: 'customer_status'
    },
    {
      title: '客户电话',
      dataIndex: 'phone'
    },
    {
      title: '领取时间',
      dataIndex: 'received_at'
    },
    {
      title: '标记时间',
      dataIndex: 'created_at'
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  transfer: [
    {
      title: '原顾问',
      dataIndex: 'af_username'
    },
    {
      title: '新顾问',
      dataIndex: 'at_username'
    },
    {
      title: '操作人',
      dataIndex: 'op_username'
    },
    {
      title: '转移时间',
      dataIndex: 'created_at'
    }
  ],
  track: [
    {
      title: '呼出时间',
      dataIndex: 'created_at'
    },
    {
      title: '绑定账号',
      dataIndex: 'account'
    },
    // {
    //   title: '呼出时长',
    //   dataIndex: 'duration'
    // },
    {
      title: '录音回听',
      dataIndex: 'url',
      scopedSlots: { customRender: 'url' }
    }
  ],
  contract: [
    {
      title: '合同编号',
      dataIndex: 'contract_no',
      width: '180px'
    },
    {
      title: '总金额',
      dataIndex: 'amount'
    },
    {
      title: '尾款',
      dataIndex: 'tail_money'
    },
    {
      title: '合同状态',
      dataIndex: 'status_format'
    },
    // {
    //   title: '提交时间',
    //   dataIndex: 'submit_check_time'
    // },
    {
      title: '所属顾问',
      dataIndex: 'adviser_name'
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  business: [
    {
      title: '合同编号',
      dataIndex: 'contract_no'
    },
    {
      title: '业务名称',
      dataIndex: 'business_name',
      scopedSlots: { customRender: 'business_name' }
    },
    {
      title: '打款金额',
      dataIndex: 'price',
      scopedSlots: { customRender: 'price' }
    },
    {
      title: '业务状态',
      dataIndex: 'status2_name',
      scopedSlots: { customRender: 'status2_name' }
    },
    {
      title: '签单人',
      dataIndex: 'username'
    },
    {
      title: '上任顾问',
      dataIndex: 'old_username'
    },
    {
      title: '操作',
      dataIndex: 'action',
      width: '100px',
      scopedSlots: { customRender: 'action' }
    }
  ],
  check: [
    {
      title: '添加顾问',
      dataIndex: 'add_name'
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '业务名称',
      dataIndex: 'tm_name',
      scopedSlots: {
        filterDropdown: 'filterDropdown',
        customRender: 'tm_name'
      }
    },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  unreceive: [
    {
      title: '信息来源',
      dataIndex: 'source',
      scopedSlots: { filterDropdown: 'filterSelect' }
    },
    {
      title: '业务大类',
      dataIndex: 'first_type',
      scopedSlots: { customRender: 'first_type' },
      filters: firstType,
      filterMultiple: false,
      onFilter: (value, record) => record.first_type.indexOf(value) === 0
    },
    {
      title: '业务名称',
      dataIndex: 'business_name',
      scopedSlots: {
        customRender: 'business_name',
        filterDropdown: 'filterDropdown'
      }
    },
    // {
    //   title: '客户姓名',
    //   dataIndex: 'customer_name',
    //   scopedSlots: { filterDropdown: 'filterDropdown' }
    // },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: {
        customRender: 'all_phone',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '入库时间',
      dataIndex: 'created_at',
      scopedSlots: {
        filterDropdown: 'filterRange'
      },
      sorter: true
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  receive: [
    {
      title: '信息来源',
      dataIndex: 'source',
      scopedSlots: { filterDropdown: 'filterSelect2' }
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '客户状态',
      dataIndex: 'customer_status',
      scopedSlots: {
        customRender: 'customer_status',
        filterDropdown: 'filterSelect1'
      }
    },
    {
      title: '业务大类',
      dataIndex: 'first_type',
      scopedSlots: { customRender: 'first_type' },
      filters: firstType,
      filterMultiple: false,
      onFilter: (value, record) => record.first_type.indexOf(value) === 0
    },
    {
      title: '业务名称',
      dataIndex: 'business_name',
      scopedSlots: {
        customRender: 'business_name',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: {
        customRender: 'phone',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '入库时间',
      dataIndex: 'created_at',
      scopedSlots: { filterDropdown: 'filterRange' },
      sorter: true
    },
    {
      title: '领取时间',
      dataIndex: 'received_at',
      scopedSlots: { filterDropdown: 'filterRange0' },
      sorter: true
    },
    {
      title: '领取人',
      dataIndex: 'username',
      scopedSlots: { filterDropdown: 'filterSelect' }
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  share: [
    {
      title: '上任顾问',
      dataIndex: 'adviser_name',
      scopedSlots: {
        filterDropdown: 'filterSelect'
      }
    },
    {
      title: '标记状态',
      dataIndex: 'customer_status',
      scopedSlots: {
        customRender: 'customer_status',
        filterDropdown: 'filterSelect1'
      }
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      scopedSlots: {
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '业务大类',
      dataIndex: 'first_type',
      scopedSlots: { customRender: 'first_type' },
      filters: firstType,
      filterMultiple: false,
      onFilter: (value, record) => record.first_type.indexOf(value) === 0
    },
    {
      title: '业务名称',
      dataIndex: 'business_name',
      scopedSlots: {
        customRender: 'business_name',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: {
        customRender: 'phone',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '最近联系时间',
      dataIndex: 'lately_contact_time',
      sorter: true
    },
    {
      title: '放弃时间',
      dataIndex: 'abandon_time',
      sorter: true
    },
    {
      title: '入库时间',
      dataIndex: 'ruku_time',
      scopedSlots: { filterDropdown: 'filterDropdown' },
      sorter: true
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  all: [
    {
      title: '客户来源',
      dataIndex: 'source',
      scopedSlots: { customRender: 'source' }
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      ellipsis: true,
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '业务大类',
      dataIndex: 'first_type',
      scopedSlots: { customRender: 'first_type' }
    },
    {
      title: '是否打款',
      dataIndex: 'amounts',
      scopedSlots: { customRender: 'amounts' }
    },
    {
      title: '业务名称',
      dataIndex: 'business_name',
      scopedSlots: {
        customRender: 'business_name',
        filterDropdown: 'filterDropdown'
      },
      ellipsis: true
    },
    {
      title: '联系电话',
      dataIndex: 'phone',
      scopedSlots: {
        customRender: 'phone',
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '领取时间',
      dataIndex: 'received_at',
      sorter: true
    },
    {
      title: '最近联系时间',
      dataIndex: 'lately_contact_time',
      sorter: true
    },
    {
      title: '所属顾问',
      dataIndex: 'username'
    },
    {
      title: '备注',
      dataIndex: 'customer_status',
      scopedSlots: { customRender: 'customer_status' },
      ellipsis: true
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  other2: [
    {
      title: '资源类型',
      dataIndex: 'type',
      scopedSlots: { customRender: 'type' }
    },
    {
      title: '注册名称',
      dataIndex: 'business_name'
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: { filterDropdown: 'filterDropdown' },
      ellipsis: true
    },
    {
      title: '微信号',
      dataIndex: 'wechat',
      scopedSlots: { customRender: 'wechat' }
    },
    {
      title: '所属顾问',
      dataIndex: 'username'
    },
    {
      title: '领取时间',
      dataIndex: 'received_at',
      sorter: true
    },
    {
      title: '操作',
      dataIndex: 'action',
      width: '210px',
      scopedSlots: { customRender: 'action' }
    }
  ],
  for_state: [
    {
      title: '资源类型',
      dataIndex: 'first_type',
      scopedSlots: { customRender: 'first_type' }
    },
    {
      title: '总数',
      dataIndex: 'loop_count'
    },
    {
      title: '0次循环',
      dataIndex: 'zero_loop'
    },
    {
      title: '1次循环',
      dataIndex: 'first_loop'
    },
    {
      title: '2次循环',
      dataIndex: 'second_loop'
    },
    {
      title: '3次循环',
      dataIndex: 'three_loop'
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  state: [
    {
      title: '所属组长',
      dataIndex: 'leader_name',
      width: '8%'
    },
    {
      title: '顾问姓名',
      dataIndex: 'username',
      width: '8%'
    },
    {
      title: '会计同行',
      dataIndex: 'kj_num',
      scopedSlots: { customRender: 'accounting' },
      sorter: true,
      width: '8%'
    },
    {
      title: '驳回复审',
      dataIndex: 'bh_num',
      scopedSlots: { customRender: 'reject' },
      sorter: true,
      width: '8%'
    },
    {
      title: '送达公告',
      dataIndex: 'sd_num',
      scopedSlots: { customRender: 'notice' },
      sorter: true,
      width: '8%'
    },
    {
      title: '设计公司',
      dataIndex: 'sj_num',
      scopedSlots: { customRender: 'iso' },
      sorter: true,
      width: '8%'
    },
    {
      title: '专利黄页',
      dataIndex: 'zl_num',
      scopedSlots: { customRender: 'ptyp' },
      sorter: true,
      width: '8%'
    },
    {
      title: '商标续展',
      dataIndex: 'xz_num',
      scopedSlots: { customRender: 'tme' },
      sorter: true,
      width: '8%'
    },
    {
      title: '商标变更',
      dataIndex: 'bg_num',
      scopedSlots: { customRender: 'tmc' },
      sorter: true,
      width: '8%'
    },
    {
      title: '预加微信量',
      dataIndex: 'yjw_num',
      scopedSlots: { customRender: 'pre_wechat' },
      sorter: true,
      width: '8%'
    },
    {
      title: '已加微信量',
      dataIndex: 'jw_num',
      scopedSlots: { customRender: 'wechat' },
      sorter: true,
      width: '10%'
    }
  ],
  add_wechat: [
    {
      title: '资源类型',
      dataIndex: 'type',
      scopedSlots: { customRender: 'type' }
    },
    {
      title: '注册名称',
      dataIndex: 'business_name'
    },
    {
      title: '客户姓名',
      dataIndex: 'customer_name',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '客户电话',
      dataIndex: 'phone',
      scopedSlots: { filterDropdown: 'filterDropdown' }
    },
    {
      title: '微信号',
      dataIndex: 'wechat',
      scopedSlots: { customRender: 'wechat' }
    },
    {
      title: '所属顾问',
      dataIndex: 'username'
    },
    {
      title: '领取时间',
      dataIndex: 'received_at',
      sorter: true
    },
    {
      title: '操作',
      dataIndex: 'action',
      width: '210px',
      scopedSlots: { customRender: 'action' }
    }
  ],
  wechat: [
    {
      title: '业务名称',
      dataIndex: 'tm_name',
      scopedSlots: { customRender: 'tm_name' }
    },
    {
      title: '联系电话',
      dataIndex: 'phone',
      scopedSlots: { customRender: 'phone' }
    },
    {
      title: '微信号',
      dataIndex: 'wx_account'
    }
  ],
  wechat_state: [
    {
      title: '组长',
      dataIndex: 'leader_name'
    },
    {
      title: '组员',
      dataIndex: 'adviser_name'
    },
    {
      title: '当日',
      dataIndex: 'today',
      sorter: true
    },
    {
      title: '当月',
      dataIndex: 'month',
      sorter: true
    },
    {
      title: '总共/平均每天',
      dataIndex: 'total',
      scopedSlots: { customRender: 'total' },
      sorter: true
    }
  ],
  import_columns: [
    {
      title: '导入记录ID',
      dataIndex: 'log_id'
    },
    {
      title: '文件名称',
      dataIndex: 'filename'
    },
    {
      title: '文件大小',
      dataIndex: 'filesize'
    },
    {
      title: '总共行数',
      dataIndex: 'total_rows'
    },
    {
      title: '成功行数',
      dataIndex: 'success_rows'
    },
    {
      title: '开始时间',
      dataIndex: 'import_start_at'
    },
    {
      title: '结束时间',
      dataIndex: 'import_end_at'
    },
    {
      title: '公司',
      dataIndex: 'company'
    },
    {
      title: '客户类型',
      dataIndex: 'customer_type'
    },
    {
      title: '状态',
      dataIndex: 'status'
    },
    {
      title: '创建时间',
      dataIndex: 'created_at'
    },
    {
      title: '操作',
      dataIndex: 'action',
      scopedSlots: { customRender: 'action' }
    }
  ],
  subject: [
    {
      title: '主体名称',
      dataIndex: 'subject',
      scopedSlots: {
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '主体类型',
      dataIndex: 'type',
      scopedSlots: {
        filterDropdown: 'filterSelect'
      }
    },
    {
      title: '联系电话',
      dataIndex: 'phone',
      scopedSlots: {
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '身份证号',
      dataIndex: 'id_card',
      scopedSlots: {
        filterDropdown: 'filterDropdown'
      }
    },
    {
      title: '资质编号',
      dataIndex: 'license_num',
      scopedSlots: {
        filterDropdown: 'filterDropdown'
      }
    },
    // {
    //   title: '身份证正面',
    //   dataIndex: 'id_card_front',
    //   scopedSlots: {
    //     customRender: 'id_card_front'
    //   }
    // },
    // {
    //   title: '身份证反面',
    //   dataIndex: 'id_card_reverse',
    //   scopedSlots: {
    //     customRender: 'id_card_reverse'
    //   }
    // },
    {
      title: '资质文件',
      dataIndex: 'license_file',
      scopedSlots: {
        customRender: 'license_file'
      }
    },
    // {
    //   title: '个人资质文件',
    //   dataIndex: 'personal_license_file',
    //   scopedSlots: {
    //     customRender: 'personal_license_file'
    //   }
    // },
    {
      title: '添加时间',
      dataIndex: 'created_at',
      scopedSlots: {
        filterDropdown: 'filterRange'
      }
    }
  ]
}
export default customerColumns
